package com.property.biz.Impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Service;

import com.property.biz.OwnerBiz;
import com.property.dao.OwnerDao;
import com.property.entity.Owner;
@Service("ownerBiz")
@Scope("prototype")
public class OwnerBizImpl implements OwnerBiz{

	@Autowired
	private OwnerDao ownerDao;
	
	public List<Owner> getAll() {
		return ownerDao.getAll();
	}

	public List<Owner> getByStatus(String status) {
		return ownerDao.getByStatus(status);
	}

	public void addOwner(Owner owner) {
		ownerDao.addOwner(owner);
		
	}

	public List<Owner> getKeyWord(int userId, String name, String tower,
			String houseIN) {
	
		return ownerDao.getKeyWord(userId, name, tower, houseIN);
	}

	public Owner getbyId(int id) {
		
		return ownerDao.getbyId(id);
	}

	public void updateOwner(Owner owner) {
		ownerDao.updateOwner(owner);
	}

	public Owner getbyIds(int id, int comid) {
		
		return ownerDao.getbyIds(id, comid);
	}

	public void updateOwners(Owner owner) {
		ownerDao.updateOwners(owner);
		
	}

	public List<Owner> getListId(int cid) {
		
		return ownerDao.getListId(cid);
	}

	public List<Owner> getKey(int userId, String name, String tower,
			String houseIN, int startIndex, int pageSize) {
		
		return ownerDao.getKey(userId, name, tower, houseIN, startIndex, pageSize);
	}

	public int rowCount(int userId, String name, String tower, String houseIN) {
		
		return ownerDao.rowCount(userId, name, tower, houseIN);
	}

	public List<Owner> getownerhouseList(int uid) {
		
		return ownerDao.getownerhouseList(uid);
	}

	public Owner getownerhousedateil(int oid) {
	
		return ownerDao.getownerhousedateil(oid);
	}

	public Owner getOwner(int id) {
		return ownerDao.getOwner(id);
	}

	public void deleteOwner(int oid) {
		ownerDao.deleteOwner(oid);
		
	}

	public void addOwnerhouse(Owner owner) {
		ownerDao.addOwnerhouse(owner);
	}

	public void delOwner(int cid) {
		ownerDao.delOwner(cid);
	}

	
	public int getOwn(int id, String tower, String houseIN) {
	
		return ownerDao.getOwn(id, tower, houseIN);
	}

	

	

	

}
